#ifndef CTCASCADER_H
#define CTCASCADER_H

#include "precomp.h"

//#include <QWidget>
//#include <QHBoxLayout>
//#include <QVBoxLayout>
//#include <QMenu>
//#include <QComboBox>
//#include <QPushButton>

class CTCascader : public QWidget
{
    Q_OBJECT
public:
    explicit CTCascader(QWidget *parent = nullptr);
    QComboBox m_combobox;
    QPushButton m_btn;
    QMenu m_contextMenu;

    void setCascadedItems(const QMap<QString, QVector<QString>>& items);
    void setCascadedItemsNew(const QMap<QString, QStringList* > &items);

signals:
    void dcascadedSelected(QString selectStr);

private slots:
    void slotPopMenu();
    void slotRewriteToBtn(QString selectStr);
};

#endif // CTCASCADER_H
